/* -----------------
* brief
* 1. this is code gen by tools
* 2. array like [a,b,c] after each field, define the ui html tag in view,
		a for title,
		b for show or not ,
		c for element html tag , currently support : check、radio、select、input、textarea、upload
* 3. XXX
*/
//使用方法：在工程root目录下，执行go generate ./modules/tenant/models
//go:generate legogen -type=TenantWxCardMch -kv=ModuleName=tenant,PrjName=saas_sys_base -dirconf=../../.. ./TenantWxCardMch.go
package tenant

import "github.com/mjiulee/lego"

func init() {
	lego.AddBeanToSynList(new(TenantWxCardMch))
}

/* table: "tb_tenant_wx_card_mch"
 * -----------------
 */
type TenantWxCardMch struct {
	Id    int64  `xorm:"pk" json:",string"`               // ["id","hide","hidden"]
	IfDel int    `xorm:"default 0"`        // ["deleted","hide","hidden"]
	Cdate string `xorm:"DateTime created"` // ["create","show","datetime"]
	Udate string `xorm:"DateTime updated"` // ["update","show","datetime"]
	// add your custom field here
	//所属信息
	TenantId  int64  `xorm:"" json:",string"`            // ["TenantId","show","input"]
	CardMchId int64  `xorm:"" json:",string"`            // ["CardMchId","show","input"] //子商户id，对于一个母商户公众号下唯一，所以要加上下面的weappid字段标识
	Weappid   string `xorm:"varchar(24)"` // ["Weappid","show","input"]

	//业务字段
	/*这个appid和上面的weappid的区别是，
	下面的appid是接口配置这个商户在微信端关联的公众号id
	而上面weappid指，我们服务端端关联的公众号id
	*/
	Appid     string `xorm:"varchar(24)"` // ["Weappid","show","input"] //目前的场景不使用此字段
	BrandName string `xorm:"char(12)"`    // ["BrandName","show","input"]
	LogoURL   string `xorm:""`            // ["LogoURL","show","upload"]
	Status    string `xorm:""`            // ["Status","show","select"]
	//资质材料保存位置，主要有3个资质材料：1. 子商户授权函、2营业执照、3. 营业执照登记者身份证照
	//ProtocolMediaId string `json:"protocol"`
	ProtocolUrl  string `xorm:""` // ["ProtocolUrl","show","upload"]
	AgreementUrl string `xorm:""` // ["AgreementUrl","show","upload"]
	OperatorUrl  string `xorm:""` // ["OperatorUrl","show","upload"]

	//所属类目
	PrimaryCategoryID   int `xorm:""` // ["OperatorUrl","show","select"]
	SecondaryCategoryID int `xorm:""` // ["OperatorUrl","show","select"]
}
